package com.iedu.demo.lgq.entity;

import java.time.LocalDateTime;
import java.util.List;

public class TbOrderReview {
    private Integer id; // 评价 ID
    private Integer itemId; // 商品 ID
    private Integer userId; // 用户 ID
    private String content; // 评价内容
    private LocalDateTime createdAt; // 评价时间
    private List<TbReviewMedia> media; // 媒体文件列表

    // 无参构造函数
    public TbOrderReview() {
    }

    // 全参构造函数
    public TbOrderReview(Integer id, Integer itemId, Integer userId, String content, LocalDateTime createdAt, List<TbReviewMedia> media) {
        this.id = id;
        this.itemId = itemId;
        this.userId = userId;
        this.content = content;
        this.createdAt = createdAt;
        this.media = media;
    }

    // Getter 和 Setter 方法
    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getItemId() {
        return itemId;
    }

    public void setItemId(Integer itemId) {
        this.itemId = itemId;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public LocalDateTime getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(LocalDateTime createdAt) {
        this.createdAt = createdAt;
    }

    public List<TbReviewMedia> getMedia() {
        return media;
    }

    public void setMedia(List<TbReviewMedia> media) {
        this.media = media;
    }

    // toString 方法
    @Override
    public String toString() {
        return "TbOrderReview{" +
                "id=" + id +
                ", itemId=" + itemId +
                ", userId=" + userId +
                ", content='" + content + '\'' +
                ", createdAt=" + createdAt +
                ", media=" + media +
                '}';
    }
}
